// Common types used throughout the app

export interface User {
    id: string;
    name: string;
    avatar?: string;
    email: string;
    streak: number; // Number of consecutive days checked in
    totalStudyTime: number; // Total study time in minutes
  }
  
  export interface StudySession {
    id: string;
    userId: string;
    date: string; // ISO date string
    duration: number; // Duration in minutes
    contentIds: string[]; // IDs of content studied
  }
  
  export interface EnglishContent {
    id: string;
    title: string;
    english: string;
    chinese: string;
    audioUrl: string;
    type: 'word' | 'phrase' | 'sentence' | 'story';
    difficulty: 'beginner' | 'intermediate' | 'advanced';
    tags: string[];
    imageUrl?: string;
  }
  
  export interface CheckIn {
    date: string; // ISO date string
    userId: string;
    isMakeup?: boolean; // Whether this was a makeup check-in
  }
  
  export interface NFCTag {
    id: string;
    contentId: string;
    lastScanned?: string; // ISO date string
  }
  
  export interface AIDialogue {
    id: string;
    keywords: string[];
    difficulty: 'beginner' | 'intermediate' | 'advanced';
    english: string;
    chinese: string;
    audioUrl?: string;
    createdAt: string; // ISO date string
  }
  
  export interface StudyStats {
    totalTime: number; // Total study time in minutes
    dailyAverage: number; // Average daily study time in minutes
    weeklyData: { date: string; minutes: number }[];
    contentTypeDistribution: { type: string; minutes: number }[];
    difficultyDistribution: { level: string; minutes: number }[];
  }